﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Web;
using System.Web.UI;
using System.Web.UI.WebControls;
using LogicAndDB;
using Common;
using System.Data.Entity;
using AccountManagement.code;
namespace AccountManagement
{
    public partial class ActivateMial : System.Web.UI.Page
    {
        protected void Page_Load(object sender, EventArgs e)
        {
            ActivationReq req = ActivationReq.ParseFromCurrentRequest();
            if (req == null) 
            {
                Response.Write("激活不成功，请重新尝试");
                return;
            }
            CUser.ActivationResult result = req.Do();

            /*用户身份验证结果 */
            switch (result)
            {
                case CUser.ActivationResult.ActivateFial:
                    Response.Write("激活不成功，请重新尝试");
                    break;
                case CUser.ActivationResult.NoExistUser:
                    Response.Write("您还没有申请账号");
                    break;
                case CUser.ActivationResult.OverTime:
                    Response.Write("您的请求已经过期，请重新申请激活");
                    break;
                case CUser.ActivationResult.Pass:
                    Response.Write("邮箱已激活!");
                    break;
            }
        }
    }
}